<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>v-cloak</title>
    <style>
        /* 属性选择器 ( attribute selector ) */
        [v-cloak] { display: none ; }
    </style>
</head>
<body>

    <h3>指令: v-cloak</h3>

    <div id="root">
        <input type="text" v-model="username">
        <p v-cloak>{{ username }}</p>
    </div>

    <script src="../scripts/vue@3.2.31.js" type="text/javascript"></script>

    <script type="text/javascript">
        setTimeout( function(){
            const options = {
                data(){
                    return {
                        username: ''
                    }
                }
            }
            Vue.createApp(options).mount('#root');
        }, 15000);
    </script>
    
</body>
</html>